﻿<CodeSnippets
    xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">
  <CodeSnippet Format="1.0.0">
    <Header>
      <Title>
        Text Box
      </Title>
    </Header>
    <Snippet>
      <Declarations>
        <Literal>
          <ID>texboxStyle</ID>
          <ToolTip>style of textbox</ToolTip>
          <Default>texboxStyle</Default>
        </Literal>
        <Literal>
          <ID>name</ID>
          <ToolTip>name of textbox</ToolTip>
          <Default>name</Default>
        </Literal>
        <Literal>
          <ID>rowNumber</ID>
          <ToolTip>row number in table</ToolTip>
          <Default>rowNumber</Default>
        </Literal>

        <Literal>
          <ID>colNumber</ID>
          <ToolTip>column number in table</ToolTip>
          <Default>columnNumber</Default>
        </Literal>

        <Literal>
          <ID>colNumber+1</ID>
          <ToolTip>column number + 1 in table</ToolTip>
          <Default>columnNumber+1</Default>
        </Literal>

        <Literal>
          <ID>Field</ID>
          <ToolTip>field of textbox</ToolTip>
          <Default>Field</Default>
        </Literal>

      </Declarations>

      <Code Language="CSharp">
        <![CDATA[
        
  <<TextBox x:Name="$name$" Grid.Row="$rowNumber$" Grid.Column="$colNumber$"  Style="{StaticResource $texboxStyle$}" 
      Text="{Binding Path=Model.$Field$, Mode=TwoWay, ValidatesOnExceptions=true, NotifyOnValidationError=true}"/>
   <csla:PropertyStatus Property="{Binding Path=Model.$Field$}" Grid.Row="$rowNumber$" Grid.Column="$colNumber+1$" />
				
        ]]>
      </Code>
    </Snippet>
  </CodeSnippet>
</CodeSnippets>
